
<%@page import="JurisPro.modelo.Agenda"%>
<%@page import="java.text.SimpleDateFormat"%>
<jsp:include page="static/cabecalhoClean.jsp"/>

     <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0" bordercolor="#CDCDCD">
     
     <tr>
       <td width="620" height="39" class="topicos">Editar Compromisso<br /></td>
     </tr>
   </table>
     <table width="100%" border="0" cellspacing="0" cellpadding="0">
       <tr>
         <td>&nbsp;</td>
       </tr>
     </table>
     
     
 	<jsp:useBean id="user" type="JurisPro.modelo.Usuario" scope="session" />
 	<jsp:useBean id="agenda" type="JurisPro.modelo.Agenda" scope="request" />
 	
     <form method="post" action="/JurisPro/do_it?" target="_top">
		<table align="center" border="0" cellpadding="0" cellspacing="0" class="tabela">
			<tr>
				<td>
				<div align="left" class="texto">Data</div>
				</td>
				<td  height="30" align="left"><label>
				<input name="idUser" type="hidden" value="<%=agenda.getIdUsuario()%>" />
				<input name="idAtividade" type="hidden" value="<%=agenda.getIdAtividade()%>" />
				<input name="comando" type="hidden" value="alterar_agenda" />  </label>
				<%
				SimpleDateFormat fmt = new SimpleDateFormat("dd/MM/yyyy");
				%>				
				<label> <input title="*Data" name="data" type="text" class="calendarSelectDate" size="15" value="<%= fmt.format(agenda.getData())  %> " /> </label>
   							<div id="calendarDiv"></div>
				
				
				</td>
				<td>
				<div align="left" class="texto" >Hora</div>
				</td>
				<td height="30" align="left"><label>
				
				<% int h = agenda.getData().getHours();
		  			int m = agenda.getData().getMinutes();
		   			String hora = ""+h;		if (h < 10) hora = "0"+h;
		   			String minuto = ""+m;	if (m < 10) minuto = "0"+m;	%>
				
				 
				<input title="*Hora" name="hora" type="text" size="15" value="<%=hora %>:<%= minuto%>" maxlength="5" id="Hora" OnKeyUp="Mascara_Hora(this.value)" /> </label></td>
			</tr>
			<tr>
				<td><div align="left" class="texto">Local</div> </td>
				<td height="30" colspan="4" align="left" class="texto">
				 <input name="local" size="50" value="<%=agenda.getLocal()%>"></input>
          		</td>
			</tr>
			
			<tr>
				<td><div align="left" class="texto">Descri&ccedil;&atilde;o</div> </td>
				<td height="30" colspan="4" align="left" class="texto">
				<label>
          			 <textarea title="*Descricao" name="descricao" id="textarea" cols="38" rows="7" ><%=agenda.getDescricao() %></textarea>
          			 </label>
				</td>				
			</tr>

			<tr>
				<td></td>
				<td><label><input type="submit" name="Submit" value="Alterar" /></label></td>
           		<td></td>
			</tr>
		</table>
		</form>
  </tr>
</table>
 
